package com.wuyou.configer;

import org.mybatis.spring.mapper.MapperScannerConfigurer;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author 闵洪友
 * @create 2020-09-02 10:14
 */
@Configuration
public class SpringBeanConfiger {
    @Bean
    public MapperScannerConfigurer scannerConfigurer(){
        MapperScannerConfigurer cfg=new MapperScannerConfigurer();
        cfg.setSqlSessionFactoryBeanName("sqlSessionFactory");
        cfg.setBasePackage("com.wuyou.mhy.dao");
        return cfg;
    }
}
